package com.hpe.aruba.CPPM.adapter;

import android.view.View;
import android.widget.TextView;

import androidx.recyclerview.widget.RecyclerView;

import com.hpe.aruba.CPPM.R;


public class CustomViewHolder extends RecyclerView.ViewHolder {
    public final TextView title;

    public interface OnViewClickListener {
        void onViewClick(View v, int adapterPosition);
    }

    public CustomViewHolder(View itemView, OnViewClickListener mListener) {
        super(itemView);
        title = itemView.findViewById(R.id.name);

        View.OnClickListener onClickListener = view -> mListener.onViewClick(view, getAdapterPosition());
        title.setOnClickListener(onClickListener);
    }

}
